import React from 'react'
// ===================================================================== Declare
const { $Lazy } = window
// ===================================================================== Lazy
const Page 		= $Lazy.load(()=>import('#tp/content/content-aside'))
const Container = $Lazy.load(()=>import('#tp/box/container'))
const Content 	= $Lazy.load(()=>import('@tp/content'))
const BackTop 	= $Lazy.load(()=>import('@antd/backTop'))
// =====================================================================
const Index = ({ children, title, controls, nobc, className, scroll, header, footer, key }) => {
	return (
		<Page key={key}>
			<Container title={title} controls={controls} nobc={nobc}>
				{ header && header }
				<div className='ex rel'>
					<Content scrollY id='pageScroll'  className={className}>
						{children}
					</Content>
				</div>
				{ footer && footer }
			</Container>
			{/* 回到顶部 */}
			<BackTop/>
		</Page>
	)
}

export default Index